package main.carteleracm.ca.utils;

import android.content.Context;
import android.content.SharedPreferences;

public class SP {
	final String nombreSP = "main.carteleracm.ca";
	public final String NULL = "NULL";
	public String PAIS = "PAIS";
	public String SALA = "SALA";
	SharedPreferences prefs;
	
	public SP(Context c){
		prefs = c.getSharedPreferences(nombreSP,Context.MODE_PRIVATE);
		SharedPreferences.Editor editor = prefs.edit();
		//editor.putString(DIAS_ACTUALIZACION, "1");
		editor.commit();
	}

	public String getString(String key){
		return prefs.getString(key, NULL);
	}
	
	public void setString(String key,String val){
		SharedPreferences.Editor editor = prefs.edit();
		editor.putString(key, val);
		editor.commit();
	}
}
